<?php

class Application_Form_Register extends Zend_Form
{
   /**
     *  <form action="page.php" method="post">
     *      <input type="text" name="blah" />
     *  </form>
     */  
	
    public function init()
    {    	
        $email = new Zend_Form_Element_Text('txtEmail');
        $email->setLabel('Email')
                  ->setRequired(true)
                  ->addValidator('NotEmpty');                 
                  
		$login = new Zend_Form_Element_Text('txtUsername');
        $login->setLabel('Username')
                  ->setRequired(true)
                  ->addValidator('NotEmpty');
                  
        $password = new Zend_Form_Element_Password('txtPassword');
        $password->setLabel('Password')
                  ->setRequired(true)
                  ->addValidator('NotEmpty');
		
	
		$submit = new Zend_Form_Element_Submit('Register');
		$submit->setLabel('Register');		
		
		$this->addElements(array($email, $login, $password, $submit))->setAction('save');		
    }
}

